Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@x-oasis/recycler

Package Overview
Dependencies
Maintainers
0
Versions
17
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@x-oasis/recycler

IntegerBufferSet function

  • 0.1.38
  • latest
  • npm
  • Socket score

Version published
Maintainers
0
Created
Source

@x-oasis/recycler

Installation

$ npm i @x-oasis/recycler

How to use

import IntegerBufferSet from '@x-oasis/recycler'

How to run test

$ pnpm test

Philosophy

Basically, give an List index then get a placed position(recycler list index); In order to reuse more elements, object ref should be considered..

For Example, remove / delete / add an element, they all cause index change of original source data. but

API

updateIndices

updateIndices(props: {
  /**
   * index in range should not be recycled
   */
  safeRange: {
    startIndex: number;
    endIndex: number;
  };
  startIndex: number;
  maxCount: number;
  step?: number;
  
  /**
   * return boolean value, true means the current processing index should be counted in.
   */
  onProcess?: (type?: string, index?: number) => boolean
})

FAQs

Package last updated on 01 Oct 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc